import service from '@/utils/request';

// 获取社群管理列表
export function getCommunityList(data) {
  return service({
    url: `/api/system/community/findCommunityPage`,
    method: 'post',
    data,
  });
}

// 社群分类下拉
export function getCommunityCategory(data) {
  return service({
    url: `/api/system/communityType/communityTypeList`,
    method: 'post',
    data
  });
}

// 社群下架
export function updateCommunityStatus(id) {
  return service({
    url: `/api/system/community/dismiss?communityId=${id}`,
    method: 'get',
  });
}

// 社群成员列表
export function getCommunityMemberList(data) {
  return service({
    url: `/api/system/community/findActivityUserInfoPage`,
    method: 'post',
    data
  });
}

// 社群留言墙
export function getCommunityActivityList(data) {
  return service({
    url: `/api/system/community/getMessageBoard`,
    method: 'post',
    data
  });
}

// 社群排序修改
export function updateCommunitySort(data) {
  return service({
    url: `/api/system/community/modifyCommunitySort`,
    method: 'post',
    data
  });
}

// 社群超级群
export function updateCommunitySuper(data) {
  return service({
    url: `/api/system/community/getCommunitySuperGroup`,
    method: 'post',
    data
  });
}
